
#ifndef SX_QCAMERA_FRAME_H
#define SX_QCAMERA_FRAME_H

#include <sxQViewportFrame.h>
#include <sxInterface_CameraView.h>

using Sx::Interface::Interface_CameraView;

namespace Sx {
namespace QtInterface {

class QCameraFrame : public QViewportFrame {
	Q_OBJECT

public:
	QCameraFrame(QWidget* parent, QViewport* viewport, const std::shared_ptr<ViewportController>& controller = nullptr, Qt::WFlags flags = 0);
	virtual ~QCameraFrame();

	bool constructToolbar();
	void setCameraView(const std::shared_ptr<Interface_CameraView>& view);

public slots:
	void onPoints();
	void onWireframe();
	void onSolid();

	void onFirstPerson();
	void onThirdPerson();

	void onLeft();
	void onRight();
	void onTop();
	void onBottom();
	void onFront();
	void onBack();

protected:
	/* Camera View interface that provides the functionality of the toolbar. */
	std::shared_ptr<Interface_CameraView> view;

	/*
	 * Toolbar buttons that change the view and display properties of the
	 * Viewport that this ViewportFrame contains.
	 * POINTER OWNERSHIP: YES
	 */
	 QToolButton *points, *wireframe, *solid;
	 QToolButton *firstPerson, *thirdPerson;
	 QToolButton *left, *right, *top, *bottom, *front, *back;
};

}

}

#endif
